package features.cases;

import com.alibaba.fastjson.JSON;
import com.gitee.ly.chain.Form;
import com.gitee.ly.chain.abstractclass.GlobalTool;
import com.gitee.ly.chain.test.form.*;

import java.util.ArrayList;
import java.util.List;

/**
 * DefaultCode
 *
 * @author ly
 **/
public class CaseParent {
    static {
        List<Form> formList = new ArrayList<>();
        formList.add(new CkjhdForm());
        formList.add(new KclsForm());
        formList.add(new RkdForm());
        formList.add(new RkjhdForm());
        formList.add(new SjdForm());
        formList.add(new KcmxForm());
        //GlobalTool.setLogInfoHandle(data -> LoggerFactory.getLogger("chain").info(data));
        GlobalTool.setLogInfoHandle(System.out::println);
        GlobalTool.setJsonSerialHandle(JSON::toJSONString);
        GlobalTool.loadChain(formList);
    }
}
